<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="PlayerList.aspx.cs" Inherits="MVP.Demo.Web.PlayerList" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Player List</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <h2>My Team's List of Players</h2>
        
        <asp:Repeater ID="playerRepeater" runat="server">
            <ItemTemplate>
                <p>
                <%# Eval("FirstName") %> <%# Eval("LastName") %><br />  
                <asp:LinkButton ID="deleteLink" runat="server" Text="Delete" CommandName="Delete" CommandArgument='<%# Eval("PlayerID") %>'></asp:LinkButton>
                </p>
            </ItemTemplate>
        </asp:Repeater>
        
        <h2>Add new player:</h2>
        First Name: <asp:TextBox ID="firstNameTextBox" runat="server"></asp:TextBox><br />
        Last Name: <asp:TextBox ID="lastNameTextBox" runat="server"></asp:TextBox><br />
        <asp:Button ID="saveButton" runat="server" Text="Save Player" />
    </div>
    </form>
</body>
</html>
